{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "from cot.generate import FRAGMENTS\n",
    "from pprint import pprint"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "{'qa-01': 'Answer the following question through step-by-step reasoning.',\n",
      " 'qa-02': 'Answer the following question through careful, concise step-by-step '\n",
      "          'reasoning.',\n",
      " 'qa-03': 'Answer the following question through careful, concise step-by-step '\n",
      "          'reasoning. Avoid making up wrong statements. If the question does '\n",
      "          'not make sense or cannot be answered, write \"I cannot answer the '\n",
      "          'question\". If you do not have a good answer, write \"I do not have a '\n",
      "          'good answer\". If you are uncertain, write \"I am uncertain about '\n",
      "          'this\".',\n",
      " 'qa-04': 'Answer the following question through careful, concise step-by-step '\n",
      "          'reasoning. Avoid making up wrong statements. Generate sub-questions '\n",
      "          'that are required to answer the original question, answer them '\n",
      "          'until you can answer the original question. If the question does '\n",
      "          'not make sense or cannot be answered, write \"I cannot answer the '\n",
      "          'question\". If you do not have a good answer, write \"I do not have a '\n",
      "          'good answer\". If you are uncertain, write \"I am uncertain about '\n",
      "          'this\".',\n",
      " 'qa-05': 'Instruction: Read the question and decide if it is easy or '\n",
      "          'difficult. If it is easy, give the answer directly without '\n",
      "          'reasoning. If it is difficult, answer it through step-by-step '\n",
      "          'reasoning.',\n",
      " 'qa-06': 'Instruction: Determine how much step-by-step thinking is required '\n",
      "          'to correctly answer the question.',\n",
      " 'qa-07': 'Instruction: Determine how much step-by-step thinking is required '\n",
      "          'to correctly answer the question. Suppose that exactly one of the '\n",
      "          'answer choices must be the right one.',\n",
      " 'qa-08': \"Let's use the following clues to answer the following \"\n",
      "          'multiple-choice question, using the following procedure:\\n'\n",
      "          \"(1) First, let's work out every answer option in a step by step way \"\n",
      "          'and consider if it is the correct option.\\n'\n",
      "          \"(2) Second, let's combine all the information gathered to be sure \"\n",
      "          'we have the right answer.\\n'\n",
      "          '(3) Third, map the answer to one of the multiple choice answers. If '\n",
      "          'you think none of the answers is correct, state that, but '\n",
      "          'nevertheless select the one of the multiple choice answers that '\n",
      "          'fits best.',\n",
      " 'qa-09': \"Let's use the following strategy to be sure we have the right \"\n",
      "          'answer:\\n'\n",
      "          \"(1) First, let's write down a step-by-step procedure of how to come \"\n",
      "          'to the right answer.\\n'\n",
      "          \"(2) Second, let's go through each of those steps.\",\n",
      " 'qa-10': 'First think step by step - describe your plan for how to get to the '\n",
      "          'right answer, written out in great detail. Then answer the '\n",
      "          'question.',\n",
      " 'qa-11': 'Instruction: First think step by step - describe your plan for how '\n",
      "          'to get to answer the question, written out in great detail. Work '\n",
      "          'your plan out in a step by step way to be sure you have the right '\n",
      "          'answer.',\n",
      " 'qa-12': 'Carefully read the question & work this out in a step by step way '\n",
      "          'to be sure you have the right answer. Be certain to spell out your '\n",
      "          'thoughts & reasoning so anyone can verify them. Spell out '\n",
      "          \"everything in painstaking detail & don't skip any steps!\",\n",
      " 'qa-13': \"Instruction: First let's rephrase the question to be sure we \"\n",
      "          \"understood it correctly. Second, let's work this out in a step by \"\n",
      "          'step by spelling out our thoughts & reasoning so anyone can verify '\n",
      "          'them. Third, make sure we have the right answer.',\n",
      " 'qa-14': 'Instruction: First, make a list of facts, which are relevant to the '\n",
      "          'question. Second, elaborate multiple times on this list of facts, '\n",
      "          'to be sure you wrote down everything that could be important. '\n",
      "          'Third, work it out in a step by step way to be sure you have the '\n",
      "          'right answer.',\n",
      " 'qa-15': 'Answer the following question through careful, concise step-by-step '\n",
      "          'reasoning. First, write down the most important facts you know '\n",
      "          'related to the question. Second, generate sub-questions that are '\n",
      "          'required to answer the original question, answer them until you can '\n",
      "          'answer the original question.',\n",
      " 'qa-16': 'Answer the following question through careful, concise step-by-step '\n",
      "          'reasoning. First, complement the question with helpful knowledge '\n",
      "          'and important additional facts. Second, generate sub-questions that '\n",
      "          'are required to answer the original question, answer them until you '\n",
      "          'can answer the original question.',\n",
      " 'qa-17': 'Create a dialog between a professor and a student. The student asks '\n",
      "          'sub-questions to the question. The professor works them out in a '\n",
      "          'step by step way and makes sure that the student understood how '\n",
      "          'they got to the right answer.',\n",
      " 'qa-18': 'Instruction: Who would be the perfect person to answer that '\n",
      "          'question correctly? What kind of expertise and additional knowledge '\n",
      "          'does this person have about the question? Write down how that '\n",
      "          'person work this out in a step by step way to be sure we have the '\n",
      "          'right answer.',\n",
      " 'qa-19': \"Instruction: Let's answer the question using two different \"\n",
      "          'approaches independent from each other:\\n'\n",
      "          \"(1) First, let's answer the question directly without reasoning.\\n\"\n",
      "          \"(2) Second, let's work this out in a step by step way to be sure we \"\n",
      "          'have the right answer.',\n",
      " 'zhou-01-ins': \"Instruction: Let's work this out in a step by step way to be \"\n",
      "                'sure we have the right answer.'}\n"
     ]
    }
   ],
   "source": [
    "pprint(FRAGMENTS[\"instructions\"])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "{'kojima-01': \"Answer: Let's think step by step.\",\n",
      " 'kojima-02': 'Answer: We should think about this step by step.',\n",
      " 'kojima-03': 'Answer: First,',\n",
      " 'kojima-04': 'Answer: Before we dive into the answer,',\n",
      " 'kojima-05': 'Answer: Proof followed by the answer.',\n",
      " 'kojima-06': \"Answer: Let's think step by step in a realistic way.\",\n",
      " 'kojima-07': \"Answer: Let's think step by step using common sense and \"\n",
      "              'knowledge.',\n",
      " 'kojima-08': \"Answer: Let's think like a detective step by step.\",\n",
      " 'kojima-09': \"Answer: Let's think about this logically.\",\n",
      " 'kojima-10': \"Answer: Let's think step by step. First,\",\n",
      " 'kojima-11': \"Answer: Let's think\",\n",
      " 'kojima-12': \"Answer: Let's solve this problem by splitting it into steps.\",\n",
      " 'kojima-13': 'Answer: The answer is after the proof.',\n",
      " 'kojima-14': \"Answer: Let's be realistic and think step by step.\",\n",
      " 'lievin-01': \"Answer: Let's derive the differential diagnosis step by step.\",\n",
      " 'lievin-02': \"Answer: Let's use step by step inductive reasoning, given the \"\n",
      "              'medical nature of the question.',\n",
      " 'lievin-03': \"Answer: Let's differentiate using step by step reasoning like a \"\n",
      "              'medical expert.',\n",
      " 'lievin-04': \"Answer: Let's think step by step using deductive reasoning.\",\n",
      " 'lievin-05': \"Answer: Let's differentiate using step by step reasoning .\",\n",
      " 'lievin-06': \"Answer: Let's think step by step to arrive at one of the \"\n",
      "              'options.',\n",
      " 'lievin-07': \"Answer: Let's break the problem into multiple steps.\",\n",
      " 'lievin-08': \"Answer: Let's use step by step deductive reasoning, given the \"\n",
      "              'medical nature of the question.',\n",
      " 'lievin-09': \"Answer: Let's think step by step like a doctor.\",\n",
      " 'lievin-10': \"Answer: Let's think step by step like a medical expert.\",\n",
      " 'lievin-11': \"Answer: Let's summarize the facts step by step.\",\n",
      " 'lievin-12': \"Answer: Let's think step by step using inductive reasoning.\",\n",
      " 'lievin-13': \"Answer: Let's think step by step using deductive reasoning like \"\n",
      "              'a medical expert.',\n",
      " 'lievin-14': \"Answer: Let's be concise and think step by step.\",\n",
      " 'lievin-15': \"Answer: Let's differentiate using step by step deductive \"\n",
      "              'reasoning like a medical expert.',\n",
      " 'lievin-16': \"Answer: Let's argue step by step.\",\n",
      " 'lievin-17': \"Answer: Let's think step by step like a clinician.\",\n",
      " 'lievin-18': \"Answer: Let's reflect on each answer option step by step.\",\n",
      " 'lievin-19': \"Answer: Let's reason and differentiate options step by step \"\n",
      "              'like a medical expert.',\n",
      " 'lievin-20': \"Answer: Let's differentiate using step by step inductive \"\n",
      "              'reasoning like a medical expert.',\n",
      " 'lievin-21': \"Answer: Let's think step by step given every option equal \"\n",
      "              'consideration.',\n",
      " 'lievin-22': \"Answer: Let's think step by step like a scientist.\",\n",
      " 'lievin-23': \"Answer: Let's use step by step inductive reasoning.\",\n",
      " 'lievin-24': \"Answer: Let's work by elimination step by step.\",\n",
      " 'lievin-25': \"Answer: Let's use step by step deductive reasoning.\",\n",
      " 'lievin-26': \"Answer: Let's follow a Bayesian step by step approach.\",\n",
      " 'lievin-27': \"Answer: Let's reflect on each option from the least likely to \"\n",
      "              'the most likely.',\n",
      " 'lievin-28': \"Answer: Let's use step by step Bayesian reasoning, given the \"\n",
      "              'medical nature of the question.',\n",
      " 'ts-01': \"Answer: Let's be logical.\",\n",
      " 'zhou-01': \"Answer: Let's work this out in a step by step way to be sure we \"\n",
      "            'have the right answer.'}\n"
     ]
    }
   ],
   "source": [
    "pprint(FRAGMENTS[\"cot_triggers\"])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "venv",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.10.6"
  },
  "orig_nbformat": 4,
  "vscode": {
   "interpreter": {
    "hash": "a19cb823e24c98ee05a9cfa4a3a579b5d56d4c1a735f2a12456750b95a1e155e"
   }
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
